Skip to content

Conversation

@itsmeichigo
Copy link
Contributor

@itsmeichigo itsmeichigo commented Sep 22, 2025

Closes WOOMOB-1234

Description

This PR adds a new model for booking and a new remote for Bookings API endpoints.

Additionally, I moved some enums from extensions to fix issue running rake generate.

Testing steps

Just CI passing is sufficient as the new code isn't used yet.

Testing information

Added unit tests for loading bookings with BookingsRemote.

Screenshots

N/A


  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

@itsmeichigo itsmeichigo added this to the 23.4 milestone Sep 22, 2025
@itsmeichigo itsmeichigo added the type: task An internally driven task. label Sep 22, 2025
@dangermattic
Copy link
Collaborator

dangermattic commented Sep 22, 2025

1 Warning
⚠️ This PR is larger than 300 lines of changes. Please consider splitting it into smaller PRs for easier and faster reviews.

Generated by 🚫 Danger

@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Sep 22, 2025

App Icon📲 You can test the changes from this Pull Request in WooCommerce iOS Prototype by scanning the QR code below to install the corresponding build.

App NameWooCommerce iOS Prototype
Build Numberpr16162-0e16d10
Version23.3
Bundle IDcom.automattic.alpha.woocommerce
Commit0e16d10
Installation URL1438mvn9of35o
Automatticians: You can use our internal self-serve MC tool to give yourself access to those builds if needed.

@itsmeichigo itsmeichigo marked this pull request as ready for review September 22, 2025 10:45
Copy link
Contributor

@RafaelKayumov RafaelKayumov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.
Pre-approving. Left a couple of questions.

public let orderID: Int64
public let orderItemID: Int64
public let parentID: Int64
public let productID: Int64
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was the person_counts skipped on purpose? Not sure though what it could be used for.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I skipped it since I'm unsure about the structure (sometimes it's an array sometimes dictionary). Since we don't have a clear idea how to use it/what for, I figure we can add it later when needed. WDYT?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm good


/// WooCommerce Bookings Plugin V1.
///
case wcBookings = "wc-bookings/v2"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it v2 or should be v1?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We will have to use v2 for the MVP. There's a long thread about testing Bookings for the MVP in p1758101141913349-slack-C03L1NF1EA3, but tl;dr you can follow the steps:

  • Create a garden site and upload the latest Bookings plugin from trunk
  • Install Code Snippets plugin and add this script define( 'WC_BOOKINGS_NEXT_ENABLED', true );

This would allow you to test the v2 API. However, I was not able to overwrite the Bookings plugin in the garden sites I created so Jorge invited me to his site instead. Let me know if you need an invitation too.

@itsmeichigo itsmeichigo merged commit 261ddc5 into trunk Sep 24, 2025
14 checks passed
@itsmeichigo itsmeichigo deleted the woomob-1374-update-networking-layer-to-support-fetching-bookings branch September 24, 2025 08:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: task An internally driven task.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants